package com.foreknow.demo8;

public class TestSingle {

    public static void main(String[] args) {

       SingleDemo single =  SingleDemo.getInstance();
       single.setName("tom");
       System.out.println(single.getName());


        SingleDemo single1 =  SingleDemo.getInstance();
        System.out.println(single1.getName());//tom


    }
}
